<?php
//หากมีการเรียกไฟล์นี้โดยตรง
if (eregi("config.in.php",$PHP_SELF)) {
    Header("Location: ../index.php");
    die();
}

// Version
define("_SCRIPT","WEB STORE");

//Web Config
if($_SERVER['SERVER_NAME'] != 'localhost'){
	define("WEB_URL","http://store.codeponpon.com") ;
}else{
	define("WEB_URL","http://localhost/store") ;
}

define("WEB_TITLE"," "._SCRIPT);
define("TIMESTAMP",time()) ;

//MySQL Connect
define("DB_HOST","localhost"); // ชื่อ host
define("DB_NAME","posterth_store"); //ชื่อฐานข้อมูล
define("DB_USERNAME","root"); // ขิ้อ user ติดต่อฐานข้อมูล
define("DB_PASSWORD","l3arn"); // รหัสผ่านติดต่อฐานข้อมูล
/*
Database:	posterth_store
Host:	    localhost
Username:	posterth_storedb
Password:	qQrVG4Kb
*/
//ตรวจสอบ IP ของผู้เข้าใช้ังานเว็บ
if ($_SERVER['HTTP_CLIENT_IP']) {
$IPADDRESS = $_SERVER['HTTP_CLIENT_IP'];
} elseif (ereg("[0-9]",$_SERVER["HTTP_X_FORWARDED_FOR"] )) {
$IPADDRESS = $_SERVER["HTTP_X_FORWARDED_FOR"];
} else {
$IPADDRESS = $_SERVER["REMOTE_ADDR"];
}
define("IPADDRESS",$IPADDRESS) ;

$bkk= mktime(gmdate("H")+7,gmdate("i")+0,gmdate("s"),
	gmdate("m") ,gmdate("d"),gmdate("Y"));
$datetimeformat="j/m/y - H:i";
$now = date($datetimeformat,$bkk);

?>

